-
Notifications
You must be signed in to change notification settings - Fork 868
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
chore(wallet): Created Asset Management Hook #11875
Conversation
5be345a
to
188ccdc
Compare
A Storybook has been deployed to preview UI for the latest push |
188ccdc
to
e115b8d
Compare
A Storybook has been deployed to preview UI for the latest push |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Left some remarks. Also one general question: why are the checkboxes so slow to reflect the state?
components/brave_wallet_ui/components/desktop/popup-modals/edit-visible-assets-modal/index.tsx
Outdated
Show resolved
Hide resolved
e115b8d
to
85aa4c2
Compare
A Storybook has been deployed to preview UI for the latest push |
85aa4c2
to
96c6947
Compare
A Storybook has been deployed to preview UI for the latest push |
96c6947
to
7def6aa
Compare
A Storybook has been deployed to preview UI for the latest push |
Description
Created an
Asset Management
hook!Before when using the
Visible Assets
modal, we would treat each action individuallyAdd, Remove, SetVisible
which would cause a refresh ofbalances/prices
every time and would also cause the selected asset to jump to the top of the list making for a bad user experience.This
hook
now allows us to pass an array oftokens
from theVisible Assets
modal after clickingDone
and will do a comparison against the usersuserVisibleTokensInfo
list, it will then make the necessary callsAdd, Remove, SetVisible
depending on what the user selected.The only action that is still treated independently is the
addCustomAsset
call, since we need to verify success from the api.Resolves brave/brave-browser#19352
Submitter Checklist:
QA/Yes
orQA/No
;release-notes/include
orrelease-notes/exclude
;OS/...
) to the associated issuenpm run test -- brave_browser_tests
,npm run test -- brave_unit_tests
,npm run lint
,npm run gn_check
,npm run tslint
git rebase master
(if needed)Reviewer Checklist:
gn
After-merge Checklist:
changes has landed on
Screen.Recording.2022-01-17.at.6.07.38.PM.mov
Screen.Recording.2022-01-19.at.12.58.24.PM.mov